import Vue from 'vue'
import Router from 'vue-router'
import ShareInvitationCode from '../view/share-invitationCode'
import roomList from '../view/room-list.vue'
import record from '../view/scratch-record.vue'
import menuItem from '../view/menuitem.vue'
import recharge from '../view/recharge.vue'
import aboutUs from '../view/about-us.vue'
import download from '../view/download.vue'
import playingRoom from '../view/playing-room.vue'
import replaceCharge from '../view/replace-charge.vue'

Vue.use(Router)

var router = new Router({
  // mode: 'history',
  routes: [
    {
      path: '/',
      redirect: '/room-list'
    },
    {
      path: '/room-list',
      name: 'room-list',
      component: roomList
    },
    {
      path: '/shareInvitationCode',
      name: 'shareInvitationCode',
      component: ShareInvitationCode
    },
    {
      path: '/scratch-record',
      name: 'scratch-record',
      component: record
    },
    {
      path: '/menuitem',
      name: 'menuitem',
      component: menuItem
    },
    {
      path: '/recharge',
      name: 'recharge',
      component: recharge
    },
    {
      path: '/about-us',
      name: 'about-us',
      component: aboutUs
    },
    {
      path: '/download',
      name: 'download',
      component: download
    },
    {
      path: '/playing-room',
      name: 'playing-room',
      component: playingRoom
    },
    {
      path: '/replace-charge',
      name: '/replace-charge',
      component: replaceCharge
    }
  ]
})

export default router
